		1 private void AlternativeAlgorithm(int noOfSeats)
        2 {
        3 
        4     ClearUserSelected();                        
        5     bool found = false;                        
        6 
        7     locState = LocaterStates.Init;                       
        8 
        9     while (!found)                              
        10    {
        11        switch (locState)                       
        12        {
        13            case LocaterStates.Init:
        14                Init();
        15                break;
        16            case LocaterStates.Middle:
        17                Middle();
        18                break;
        19            case LocaterStates.LeftMove:
        20                LeftMove();
        21                break;
        22            case LocaterStates.RightMove:
        23                RightMove();
        24                break;
        25            case LocaterStates.Found:
        26                found = Found(noOfSeats);       
        27                break;
        28        }
        29    }
        30}